package com.ay.example;

import com.ay.service.XiaohongshuService;
import com.ay.mapper.ChannelAdvertisersMapper;
import java.io.IOException;

public class XiaohongshuExample {
    public static void main(String[] args) {
        // 替换为您的访问令牌
        String accessToken = "your_access_token";
        XiaohongshuService service = new XiaohongshuService(accessToken);
        ChannelAdvertisersMapper mapper = new ChannelAdvertisersMapper(); // 替换为实际的Mapper实例
        
        try {
            // 使用新的分页方法获取所有账户信息
            service.getAllAdAccountInfo("638dadad000000001f01d8bf", mapper);
            System.out.println("数据同步完成");
            
        } catch (IOException e) {
            System.err.println("调用API时发生错误：" + e.getMessage());
            e.printStackTrace();
        }
    }
} 